class FetchSelectOptionsAction {
    constructor() {
        this.filterActionType = "fetch-select-options"
    }
    createInitParam(action) {
       action.params["filter"] = action.params["filter"] || "catagory=XZQH";
    }
    renderActionConfig(action) {
        let html = `
          <div class="form-group">
            <label>目标字段</label>
            <input type="text" id="actionTargetField" value="${action.targetField || ''}" />
          </div>
          <div class="form-group">
            <label>列表数据过滤器</label>
            <input type="text" id="actionFilterField" value="${action.params["filter"] || ''}" />
          </div>
        `;
        return html;
    }
    collectActionConfig(action) {
        action.targetField = document.getElementById("actionTargetField").value;
        action.params["filter"] = document.getElementById("actionFilterField").value;
    }
}
export default new FetchSelectOptionsAction();
